/* 全局样式 */
:root {
  --primary-color: #4361ee;
  --primary-light: #5e7cff;
  --secondary-color: #3a0ca3;
  --accent-color: #f72585;
  --accent-light: #ff4da6;
  --text-dark: #1a1a2e;
  --text-light: #8d99ae;
  --glass-bg: rgba(255, 255, 255, 0.25);
  --glass-border: rgba(255, 255, 255, 0.4);
  --glass-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
  --success-color: #4cc9f0;
}

body {
  font-family: "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI",
    Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: linear-gradient(135deg, #e0f2ff, #c7d9ff);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  margin: 0;
  padding: 20px;
  overflow: hidden;
  position: relative;
  color: var(--text-dark);
}

/* 主容器 */
.main-container {
  background: var(--glass-bg);
  border-radius: 24px;
  box-shadow: var(--glass-shadow), 0 0 0 1px rgba(255, 255, 255, 0.1) inset,
    0 0 40px rgba(255, 255, 255, 0.2) inset;
  padding: 40px 30px;
  width: 90%;
  max-width: 500px;
  text-align: center;
  animation: fadeIn 1.2s cubic-bezier(0.22, 1, 0.36, 1);
  position: relative;
  z-index: 1;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  overflow: hidden;
}

.main-container::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.1) 0%,
    rgba(255, 255, 255, 0) 70%
  );
  opacity: 0;
  transition: opacity 0.6s ease;
  pointer-events: none;
}

.main-container:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 60px rgba(31, 38, 135, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.2) inset,
    0 0 60px rgba(255, 255, 255, 0.3) inset;
}

.main-container:hover::before {
  opacity: 1;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 标题 */
h1 {
  color: var(--text-dark);
  font-size: 2.4rem;
  margin: 0 0 30px;
  font-weight: 700;
  letter-spacing: -0.5px;
  position: relative;
  display: inline-block;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

h1::after {
  content: "";
  position: absolute;
  bottom: -12px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
  border-radius: 4px;
  box-shadow: 0 2px 12px rgba(247, 37, 133, 0.4);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.main-container:hover h1::after {
  width: 100px;
  background: linear-gradient(90deg, var(--primary-light), var(--accent-light));
  box-shadow: 0 2px 16px rgba(247, 37, 133, 0.6);
}

/* 倒计时部分 */
.countdown-section {
  margin-bottom: 35px;
  position: relative;
}

.countdown {
  font-size: 3.5rem;
  background: linear-gradient(
    135deg,
    var(--primary-color),
    var(--accent-color)
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-weight: 700;
  margin: 0;
  line-height: 1.2;
  text-shadow: 0 4px 20px rgba(67, 97, 238, 0.4);
  animation: pulse 2s ease-in-out infinite alternate;
  position: relative;
  display: inline-block;
  padding: 0 20px;
}

.countdown::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    rgba(67, 97, 238, 0.1),
    rgba(247, 37, 133, 0.1)
  );
  border-radius: 20px;
  z-index: -1;
  opacity: 0;
  transition: all 0.4s ease;
  transform: scale(0.95);
}

.main-container:hover .countdown::before {
  opacity: 1;
  transform: scale(1);
}

@keyframes pulse {
  0% {
    transform: scale(1);
    text-shadow: 0 4px 20px rgba(67, 97, 238, 0.4);
  }
  100% {
    transform: scale(1.05);
    text-shadow: 0 6px 30px rgba(67, 97, 238, 0.6);
  }
}

/* 当前时间部分 */
.time-section {
  border-top: 1px solid rgba(255, 255, 255, 0.3);
  padding-top: 25px;
  margin: 0 auto;
  max-width: 80%;
  position: relative;
}

.time-section::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.7),
    transparent
  );
}

.time-display {
  font-size: 2rem;
  color: var(--text-dark);
  font-weight: 600;
  margin: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.time-display span:not(.colon) {
  background: rgba(255, 255, 255, 0.3);
  padding: 8px 15px;
  border-radius: 12px;
  min-width: 60px;
  display: inline-block;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08),
    0 0 0 1px rgba(255, 255, 255, 0.1) inset;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.main-container:hover .time-display span:not(.colon) {
  background: rgba(255, 255, 255, 0.4);
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12),
    0 0 0 1px rgba(255, 255, 255, 0.2) inset;
}

.time-display .colon {
  animation: blink 1.5s infinite;
  position: relative;
  top: -3px;
  color: var(--accent-color);
  font-weight: 700;
  text-shadow: 0 0 10px rgba(247, 37, 133, 0.5);
}

@keyframes blink {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.5;
    transform: scale(0.9);
  }
}

/* 提示语部分 */
.tip-section {
  margin-top: 35px;
  padding: 25px;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.4),
    rgba(245, 245, 255, 0.5)
  );
  border-radius: 18px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1),
    0 0 0 1px rgba(255, 255, 255, 0.2) inset;
  animation: slideIn 1.5s cubic-bezier(0.22, 1, 0.36, 1);
  border: 1px solid rgba(255, 255, 255, 0.4);
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.main-container:hover .tip-section {
  transform: translateY(-5px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15),
    0 0 0 1px rgba(255, 255, 255, 0.3) inset;
}

.tip-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 6px;
  height: 100%;
  background: linear-gradient(
    to bottom,
    var(--primary-color),
    var(--accent-color)
  );
  transition: all 0.4s ease;
}

.main-container:hover .tip-section::before {
  width: 8px;
  background: linear-gradient(
    to bottom,
    var(--primary-light),
    var(--accent-light)
  );
}

.tip-section::after {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.2) 0%,
    rgba(255, 255, 255, 0) 70%
  );
  opacity: 0;
  transition: all 0.6s ease;
}

.main-container:hover .tip-section::after {
  opacity: 0.6;
}

.tip-text {
  font-size: 1.2rem;
  color: var(--text-dark);
  line-height: 1.7;
  margin: 0;
  font-weight: 500;
  font-style: italic;
  position: relative;
  z-index: 1;
  transition: all 0.3s ease;
}

.main-container:hover .tip-text {
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.6);
}

@keyframes slideIn {
  from {
    transform: translateY(30px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* 装饰元素 */
.floating-element {
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.3;
  z-index: -1;
  animation: float 12s ease-in-out infinite;
}

.floating-element-1 {
  width: 200px;
  height: 200px;
  background: var(--primary-color);
  top: 10%;
  right: 10%;
}

.floating-element-2 {
  width: 150px;
  height: 150px;
  background: var(--accent-color);
  bottom: 10%;
  left: 10%;
  animation-delay: 2s;
}

.floating-element-3 {
  width: 180px;
  height: 180px;
  background: var(--success-color);
  top: 60%;
  left: 20%;
  animation-delay: 4s;
}

@keyframes float {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }
  25% {
    transform: translate(20px, 20px) rotate(5deg);
  }
  50% {
    transform: translate(0, 40px) rotate(0deg);
  }
  75% {
    transform: translate(-20px, 20px) rotate(-5deg);
  }
}

/* 流星效果 */
.meteor {
  position: absolute;
  width: 2px;
  height: 2px;
  background: white;
  border-radius: 50%;
  box-shadow: 0 0 10px 2px white;
  opacity: 0;
  z-index: -1;
  animation: meteor 3s linear infinite;
}

@keyframes meteor {
  0% {
    transform: translateX(0) translateY(0);
    opacity: 1;
  }
  70% {
    opacity: 1;
  }
  100% {
    transform: translateX(500px) translateY(300px);
    opacity: 0;
  }
}

/* 响应式设计 */
@media screen and (max-width: 480px) {
  h1 {
    font-size: 2rem;
  }

  .countdown {
    font-size: 2.8rem;
  }

  .time-display {
    font-size: 1.6rem;
  }

  .time-display span:not(.colon) {
    min-width: 50px;
    padding: 6px 12px;
  }

  .tip-text {
    font-size: 1.1rem;
  }

  .main-container {
    padding: 30px 20px;
    border-radius: 20px;
  }
}
